/***
 * formSize(String):表单大小 small mini large
 * type(String):表单类型 text | select | date | checkbox | radio
 * inputType(String):input类型
 * label(String):字段名称
 * labelWidth(String):字段宽度 150px
 * placeholder(String):默认显示
 * isReadOnly(Bollean):是否只读
 * isDisabled(Bollean):是否禁止
 * isRequired(Bollean):是否必填
 * optionList(Array):如果是下拉，复选，单选的数据源
 * keyName(String):有数据源的情况下，绑定的key字段名
 * valName(String):有数据源的情况下，绑定的label字段名
 * maxlength(Number):最大输入长度
 * colSpan(Number):占位符
 * isAppendRightBtn(Boolean):是否显示input右侧的按钮类型
 * appendRightBtnType(String):input右侧的按钮类型
 * appendRightBtnTxt(String):input右侧的按钮文字
 * bindFieldName(String):绑定后段字段名称
 * bindFieldVal(String):双向绑定绑定的具体值，一般用于readonly或者disabled的情况下直接赋值
 * buttonTxt(String):type为button时的按钮内容文字
 * influenceFiledName(String):二级联动所关联的select的后段字段->bindFieldName
 */

//客户信息
const clientInfoFiledList = [{
    type: 'select',
    colSpan: 8,
    optionList: [{
      dictKey: 1,
      dictValue: "企业"
    }, {
      dictKey: 2,
      dictValue: "个人"
    }],
    keyName: 'dictKey',
    valName: 'dictValue',
    label: '客户类型',
    isRequired: false,
    isDisabled: true,
    bindFieldVal: "",
    bindFieldName: 'partnerCategory',
    placeholder: "--",
  }, {
    type: 'text',
    label: '客户名称',
    isRequired: false,
    isReadOnly: true,
    bindFieldName: 'partnerName',
    placeholder: "--",
    bindFieldVal: ""
  }, {
    type: 'text',
    label: '品牌',
    isRequired: false,
    isReadOnly: true,
    bindFieldName: 'operateBrandName',
    placeholder: "--",
    bindFieldVal: ""
  }, {
    type: 'text',
    label: '行态/行业',
    isRequired: false,
    isReadOnly: true,
    bindFieldName: 'industryName',
    placeholder: "--",
    bindFieldVal: ""
  }, {
    type: 'date',
    label: '最初合作时间',
    isRequired: false,
    isDisabled: true,
    bindFieldName: 'firstCooperationDate',
    placeholder: "--",
    bindFieldVal: ""
  }, {
    type: 'text',
    label: '合作状态',
    isRequired: false,
    isReadOnly: true,
    bindFieldName: 'contractStatus',
    placeholder: "--",
    bindFieldVal: ""
  }, {
    type: 'text',
    label: '收入贡献',
    isRequired: false,
    isReadOnly: true,
    bindFieldName: 'paymentAmount',
    placeholder: "--",
    bindFieldVal: ""
  },
  {
    type: 'select',
    colSpan: 8,
    optionList: [{
      dictKey: 1,
      dictValue: "是"
    }, {
      dictKey: 0,
      dictValue: "否"
    }],
    keyName: 'dictKey',
    valName: 'dictValue',
    label: '客户类型',
    isRequired: false,
    isDisabled: true,
    bindFieldVal: "",
    bindFieldName: 'ifBlackList',
    placeholder: "--",
  }
]

//客户信息新
const clientInfoFiledNewList = [{
    type: 'text',
    label: '客户名称',
    placeholder: '--',
    isRequired: false,
    isReadOnly: true,
    labelWidth: "110px",
    bindFieldName: 'partnerName',
    bindFieldVal: '',
  }, {
    type: 'text',
    label: '客户简称',
    placeholder: '--',
    isRequired: false,
    isReadOnly: true,
    bindFieldName: 'partnerShortName',
    bindFieldVal: '',
  }, {
    type: 'select',
    colSpan: 8,
    optionList: [{
      dictKey: 1,
      dictValue: "企业"
    }, {
      dictKey: 2,
      dictValue: "个人"
    }],
    keyName: 'dictKey',
    valName: 'dictValue',
    label: '客户类型',
    isRequired: false,
    isDisabled: true,
    bindFieldVal: "",
    bindFieldName: 'partnerCategory',
    placeholder: "--",
  }, {
    type: 'text',
    label: '经营业务',
    isRequired: false,
    isReadOnly: true,
    bindFieldName: 'industryName',
    placeholder: "--",
    bindFieldVal: ""
  }, {
    type: 'text',
    label: '品牌',
    isRequired: false,
    isReadOnly: true,
    bindFieldName: 'operateBrandName',
    placeholder: "--",
    bindFieldVal: ""
  }, {
    type: 'radio',
    label: '黑白名单',
    isRequired: false,
    isDisabled: true,
    bindFieldName: 'ifBlackList',
    placeholder: "--",
    bindFieldVal: "",
    optionList: [{
      dictKey: 1,
      dictValue: "是"
    }, {
      dictKey: 0,
      dictValue: "否"
    }],
    keyName: 'dictKey',
    valName: 'dictValue',
  }, {
    type: 'text',
    label: '客户状态',
    isRequired: false,
    isReadOnly: true,
    bindFieldName: 'contractStatus',
    placeholder: "--",
    bindFieldVal: ""
  },
  {
    type: 'select',
    label: '标签',
    placeholder: '请选择',
    isRequired: false,
    colSpan: 16,
    optionList: [],
    keyName: 'primaryKey',
    valName: 'name',
    isMultiple: true,
    bindFieldName: 'tagList',
    bindFieldVal: '',
  }
]

//当期客户的查询条件
const searchClientCurrentList = [{
  type: 'select',
  label: '项目名称',
  placeholder: '请选择',
  isRequired: false,
  optionList: [],
  keyName: 'projectKey',
  valName: 'projectName',
  labelWidth: "110px",
  bindFieldName: 'projectKey',
  bindFieldVal: '',
}, {
  type: 'text',
  label: '客户名称',
  placeholder: '请输入',
  isRequired: false,
  bindFieldName: 'likePartnerName',
  bindFieldVal: '',
}, {
  type: 'text',
  label: '客户简称',
  placeholder: '请输入',
  isRequired: false,
  bindFieldName: 'likePartnerShortName',
  bindFieldVal: '',
}, {
  type: 'select',
  label: '客户类型',
  placeholder: '请选择',
  isRequired: false,
  optionList: [{
    key: 1,
    value: "企业"
  }, {
    key: 2,
    value: "个人"
  }],
  keyName: 'key',
  valName: 'value',
  isMultiple: true,
  bindFieldName: 'partnerCategorys',
  bindFieldVal: '',
}, {
  type: 'select',
  label: '业态/行业',
  placeholder: '请选择',
  isRequired: false,
  optionList: [],
  keyName: 'primaryKey',
  valName: 'catalogName',
  isMultiple: true,
  bindFieldName: 'industryTypeList',
  bindFieldVal: '',
}, {
  type: 'select',
  label: '品牌',
  placeholder: '请选择',
  isRequired: false,
  optionList: [],
  keyName: 'primaryKey',
  valName: 'catalogName',
  isDisabled: true,
  isMultiple: true,
  bindFieldName: 'operateBrandList',
  bindFieldVal: '',
}, {
  type: 'select',
  label: '是否黑名单',
  isRequired: false,
  bindFieldName: 'ifBlackList',
  bindFieldVal: '',
  optionList: [{
    key: 0,
    value: "否"
  }, {
    key: 1,
    value: "是"
  }],
  keyName: 'key',
  valName: 'value',
}]

//历史客户的查询条件
const searchClientHistoryList = [{
    type: 'select',
    label: '项目名称',
    placeholder: '请选择',
    isRequired: false,
    optionList: [],
    keyName: 'projectKey',
    valName: 'projectName',
    labelWidth: "120px",
    bindFieldName: 'projectKey',
    bindFieldVal: '',
  }, {
    type: 'date',
    label: '经营开始时间',
    placeholder: '请选择',
    isRequired: false,
    bindFieldName: 'rangeRentStartDate',
    bindFieldVal: ""
  }, {
    type: 'date',
    label: '经营结束时间',
    placeholder: '请选择',
    isRequired: false,
    bindFieldName: 'rangeRentEndDate',
    bindFieldVal: ""
  },
  {
    type: 'text',
    label: '客户名称',
    placeholder: '请输入',
    isRequired: false,
    bindFieldName: 'likePartnerName',
    bindFieldVal: '',
  }, {
    type: 'select',
    label: '客户类型',
    placeholder: '请选择',
    isRequired: false,
    optionList: [{
      key: 1,
      value: "企业"
    }, {
      key: 2,
      value: "个人"
    }],
    keyName: 'key',
    valName: 'value',
    isMultiple: true,
    bindFieldName: 'partnerCategorys',
    bindFieldVal: '',
  }, {
    type: 'select',
    label: '业态/行业',
    placeholder: '请选择',
    isRequired: false,
    optionList: [],
    keyName: 'primaryKey',
    valName: 'catalogName',
    isMultiple: true,
    bindFieldName: 'industryTypeList',
    bindFieldVal: '',
  }, {
    type: 'select',
    label: '品牌',
    placeholder: '请选择',
    isRequired: false,
    optionList: [],
    keyName: 'primaryKey',
    valName: 'catalogName',
    isMultiple: true,
    isDisabled: true,
    bindFieldName: 'operateBrandList',
    bindFieldVal: '',
  }
]

export {
  clientInfoFiledList,
  clientInfoFiledNewList,
  searchClientCurrentList,
  searchClientHistoryList
}
